home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Treccani Italiana Di Scienze Lettere Ed Arti
/
[Enciclopedia] Treccani Italiana di scienze lettere ed arti.iso
/
pc
/
data
/
xxi_appendice_dvd.swf
/
scripts
/
__Packages
/
CAppendiceThumb.as
< prev
next >
Wrap
Text File
|
2007-11-08
|
2KB
|
89 lines
class CAppendiceThumb extends mx.core.UIObject
{
function CAppendiceThumb()
{
super();
this.mInitialized = false;
this.Hide();
this.doLater(this,"init");
}
function init()
{
this.mInitialized = true;
this.mc_ImgTitolo.html = true;
this.mc_ImgTitolo.multiline = true;
this.mc_ImgTitolo.embedFonts = _global.gUseEmbeddedFont;
this.mc_ImgTitolo.styleSheet = _global.gStyleManager.GetCSS();
this.mc_ImgThumb.addEventListener("progres",mx.utils.Delegate.create(this,this.onThumbLoadingProgress));
this.mc_ImgThumb.addEventListener("complete",mx.utils.Delegate.create(this,this.onThumbLoadingComplete));
this.mc_ImgThumb.setStyle("border","solid");
this.mc_ImgIcona.setStyle("border","solid");
}
function LayoutWindow()
{
}
function onPress()
{
if(_root.gAppendiceSearch)
{
this.mMedia.mFrom = "lemma";
if(this.mMedia.mTipo == "P")
{
_root.gAppendiceSearch.MostraProspettiva(this.mMedia.mId,"P",this.mMedia.mTitolo,"lemma",true);
}
else
{
_root.gAppendiceSearch.OpenContributiWindow(this.mMedia);
}
}
}
function IconManager(tipo)
{
switch(tipo)
{
case "L":
return "lemmaIconBig";
case "R":
return "rinvioIconBig";
case "T":
return "tabIconBig";
case "I":
return "imageIconBig";
case "F":
return "imageIconBig";
case "P":
return "prospettivaIconBig";
default:
return "emptyIcon";
}
}
function onThumbLoadingProgress(evtObj)
{
}
function onThumbLoadingComplete(evtObj)
{
}
function SetMedia(inMedia)
{
this.mMedia = inMedia;
this.mc_ImgTitolo.htmlText = "<span class=\'s_titoloThumbPreview\'>" + StringUtils.HtmlFunction(inMedia.mTitolo) + "</span>";
this.mc_ImgThumb.__set__contentPath(inMedia.GetThumbPath());
this.mc_ImgIcona.__set__contentPath(this.IconManager(inMedia.mTipo));
this.Show();
}
function Hide(Void)
{
this._visible = false;
}
function Show(Void)
{
if(!this._visible)
{
this._visible = true;
}
}
function clearUI()
{
}
}